# Author:lzhan  Date:2020/3/16
import requests
# 搜索的目的地
url='http://search.jumei.com/?filters=0-11-1&'
# 搜索的内容
condition={"search":"香水"}
# 发送请求的主体
user_agent='User-Agent:Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.94 Safari/537.36'
# 伪装成浏览器
my_headers={"User-Agent":user_agent}
response=requests.get(url,params=condition,headers=my_headers)

#  'json', 'links', 'next', 'ok', 'raise_for_status', 'raw', 'reason', 'request', 'status_code', 'text', 'url'

# print(response.status_code)
# print(response.reason)
# print(response.url)

# print(response.content)

tt=response.text
with open('data/pages/jumei_perfume_01.html','w') as fp:
    fp.write(tt)









